package edu.zut.hb.software.train.Way.domain;



import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import edu.zut.hb.software.base.domain.BaseEntity;




@Table(name="T_Way")  //表名
@Entity    //实体
/*@NamedQueries({ @NamedQuery(name = "Way.getRoot", query = "select g from Way g where g.parent is null") })*/
public class Way extends BaseEntity{

	/**
	 * 
	 */
	private static final long serialVersionUID = -31279394964769200L;
	
    @Id
	@Column(name = "Id")
	Long id;
	



	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	@Column( name = "WAY")
	String way;
 
	
	String time;
	
//	@OneToMany(mappedBy = "p", cascade = CascadeType.REMOVE, fetch = FetchType.EAGER)
	//Set<Site> receivables;

	public String getway() {
		return way;
	}

	public String getTime() {
		return time;
	}
//
//	public Set<Site> getSite() {
//		return Site;
//	}
//
//	public void setWay(String way) {
//		this. way = way;
//	}
//
//	public void setTime(String time) {
//		this.time = time;
//	}
//
//	public void setSite(Set<Site> site) {
//		this.site = site;
//	}

	public void setWay(String way) {
		this.way = way;
	}

	public void setTime(String time) {
		this.time = time;
	}

	@Override
	public String toString() {
		return "Way [id=" + id + ", way=" + way + ", time=" + time + "]";
	}

	/**
	 * 
	 
	@GeneratedValue(strategy=GenerationType.AUTO)   //生成主键的策略
	@Id  //主键
	public Long getId() {
		return id;
	}
	public void setId(Long id) {
		this.id = id;
	}
	
	@Column(name="LASTWAY",length=50,nullable=false)
	public String getWay() {
		return way;
	}
	public void setWay(String way) {
		this.way = way;
	}
	public String getPrice() {
		return price;
	}
	public void setPrice(String price) {
		this.price = price;
	}
	*/
	
	
	
}
